From f73aa9c6a4b367badc7eb641c08d5de2a8a13698 Mon Sep 17 00:00:00 2001 From: robertl Date: Thu, 12 Jun 2003 23:54:04 +0000 Subject: [PATCH] solidify duplicate sort states in testo --- gpsbabel/testo | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/gpsbabel/testo b/gpsbabel/testo index cdfc4cd19..d9ffc76c4 100755 --- a/gpsbabel/testo +++ b/gpsbabel/testo @@ -14,6 +14,13 @@ compare() } } +sort_and_compare() +{ + sort $1 > $TMPDIR/s1 + sort $2 > $TMPDIR/s2 + compare $TMPDIR/s1 $TMPDIR/s2 +} + # Geocaching .loc rm -f ${TMPDIR}/gl.loc @@ -227,7 +234,7 @@ rm -f ${TMPDIR}/filterdupe.csv1 ${TMPDIR}/filterdupe.csv2 ${PNAME} -i geo -f geocaching.loc -o csv -F ${TMPDIR}/filterdupe.csv1 ${PNAME} -i geo -f geocaching.loc -f geocaching.loc -x duplicate,shortname \ -o csv -F ${TMPDIR}/filterdupe.csv2 -compare ${TMPDIR}/filterdupe.csv1 ${TMPDIR}/filterdupe.csv2 +sort_and_compare ${TMPDIR}/filterdupe.csv1 ${TMPDIR}/filterdupe.csv2 # # Position filter - Since very small distances are essentialy a duplicate @@ -237,7 +244,7 @@ rm -f ${TMPDIR}/filterpos.csv1 ${TMPDIR}/filterpos.csv2 ${PNAME} -i geo -f geocaching.loc -o csv -F ${TMPDIR}/filterpos.csv1 ${PNAME} -i geo -f geocaching.loc -f geocaching.loc -x position,distance=5f \ -o csv -F ${TMPDIR}/filterpos.csv2 -compare ${TMPDIR}/filterpos.csv1 ${TMPDIR}/filterpos.csv2 +sort_and_compare ${TMPDIR}/filterpos.csv1 ${TMPDIR}/filterpos.csv2 # # Radius filter -- 2.30.2